package com.hoas.quickstart.threads.chapter02.chapter02_2_16_01;

public class Run1 {

    public static void main(String[] args) {
        MyService service = new MyService();

        ThreadA threadA = new ThreadA( service );
        threadA.setName("A");

        ThreadB threadB = new ThreadB( service );
        threadB.setName("B");

        threadA.start();

        try {
            Thread.sleep(50);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        threadB.start();

    }

}
